import styled from 'styled-components'

export const Container = styled.div`
    display: flex;
    margin-bottom: 100px;
    @media (max-width: 1200px) {
        flex-direction: column-reverse;
        margin-bottom: 50px;
    }
    .left{
        flex: 1;
        width: 0;
        margin-right: 20px;
        @media (max-width: 1200px) {
            width: auto;
            margin-left: 20px;
            margin-top: 60px;
        }
        .desc{
            display: flex;
            flex-direction: column;
            align-items: center;
            padding: 16px 0;
            .welcome{
                height: 30px;
                margin: 10px 0;
                font-family: webfont;
            }
            .desc-item{
                font-size: 16px;
                font-weight: bold;
                color: ${props=>props.theme.descColor};
                padding: 0 50px;
                text-align: center;
                span{
                    margin-left: 6px;
                }
                p{
                    font-size: 12px;
                    font-style: italic;
                    text-align: right;
                    margin-top: 12px;
                }
            }
        }
        .link{
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 12px 20px;
            img{
                width: 24%;
                max-width: 80px;
            }
            .link-right{
                padding: 0 14px;
                border-right: 1px solid #eee;
                flex: 1;
                max-width: 14em;
                .link-right-title{
                    color: ${props=>props.theme.descColor};
                    font-weight: bold;
                }
                .link-right-subtitle{
                    color: #999;
                    font-size: 12px;
                    margin-top: 6px;
                }
            }
            .link-money{
                width: 30px;
                height: 30px;
                border-radius: 50%;
                margin-left: 24px;
                border: 1px solid #faad14;
                display: flex;
                align-items: center;
                justify-content: center;
                cursor: pointer;
                transition: all 0.3s;
                &:hover{
                    transform: scale(1.2);
                    transition: all 0.3s;
                }
            }
        }
        .guess{
            display: flex;
            flex-direction: column;
            width: 100%;
            .guess-item{
                width: 100%;
                padding: 14px 28px;
                transition: ease-in-out 0.3s;
                display: flex;
                position: relative;
                overflow: hidden;
                cursor: pointer;
                color: ${props=>props.theme.cardListColor};
                .line{
                    position: absolute;
                    width: 4px;
                    height: 100%;
                    top: 0;
                    left: -4px;
                    background-color: #1890ff;
                    transition: ease-in-out 0.3s;
                }
                .title{
                    display: flex;
                    align-items: center;
                    width: 100%;
                    &.like{
                        flex: 1;
                        width: 0;
                        display: block;
                        overflow: hidden;
                        white-space: nowrap;
                        text-overflow: ellipsis;
                    }
                    .num{
                        display: inline-block;
                        width: 20px;
                        height: 20px;
                        margin-left: 4px;
                        margin-right: 8px;
                        background-color: #1890ff;
                        border-radius: 50%;
                        display: flex;
                        align-items: center;
                        justify-content: center;
                        color: #f5f5f5;
                    }
                    .value{
                        flex: 1;
                        width: 0;
                        display: inline-block;
                        overflow: hidden;
                        white-space: nowrap;
                        text-overflow: ellipsis;
                    }
                }
                &:hover{
                    background-color: ${props=>props.theme.cardListHoverBg};
                    color: #1890ff;
                    transition: ease-in-out 0.3s;
                    .line{
                        left: ${window.isMobile ? '-4px' : '0'};
                        transition: ease-in-out 0.3s;
                    }
                }
            }
        }
    }
    .right{
        flex: 2;
        .article-top-notice{
            padding: 8px 24px;
            display: flex;
            @media (max-width: 1200px) {
                padding-bottom: 0px;
                padding-top: 16px;
            }
            .article-top-notice-title{
                max-width: 100%;
                overflow: hidden;
                white-space: nowrap;
                text-overflow: ellipsis;
            }
        }
        .article-item{
            border-color: ${props=>props.theme.articleItemBorderColor};
            .ant-list-item-action > li{
                color: ${props=>props.theme.articleActionColor};
            }
        }
        .article-title-c{
            display: flex;
            align-items: center;
            .article-title{
                flex: 1;
                width: 0;
                display: inline-block;
                cursor: pointer;
                overflow: hidden;
                text-overflow: ellipsis;
                white-space: nowrap;
                transition: color 0.3s;
                color: ${props=>props.theme.articleTitleColor};
                &:hover{
                    color: #1890ff;
                    transition: color 0.3s;
                }
            }
        }
        .article-cover{
            width: 260px;
            height: 130px;
            overflow: hidden;
            border-radius: 8px;
            box-shadow: 0 0 8px 2px ${props=>props.theme.articleCoverShadow};
            .article-cover-img{
                width: 100%;
                height: 100%;
                object-fit: cover;
                transition: transform 0.3s;
                &:hover{
                    transform: scale(1.3);
                    transition: transform 0.3s;
                }
            }
            @media (max-width: 1200px) {
                width: 100%;
                max-width: 320px;
                height: 150px;
                .article-cover-img:hover{
                    transform: none;
                }
            }
        }
        .article-desc{
            font-size: 13px;
            line-height: 20px;
            height: 60px;
            overflow: hidden;
            color: ${props=>props.theme.articleDescColor};
        }
    }
`